﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MVCGenerator
{
    public class SpaceStack
    {
        const int NumberOfSpacesPerLevel = 4;

        private int StackSize;
        public SpaceStack(int InitialSize = 0)
        {
            StackSize = InitialSize;
        }

        public override string ToString()
        {
            int NumberOfSpaces = StackSize * NumberOfSpacesPerLevel;
            return "".PadRight(NumberOfSpaces,' ');
        }

        public void Add()
        {
            StackSize = StackSize + 1;
        }

        public void Remove()
        {
            if (StackSize > 0)
            {
                StackSize = StackSize - 1;
            }
        }
    }
}
